;(function () {
    const template = `<div class="table-responsive">
                    <table class="table table-striped">
                        <thead>
                        <tr>
                            <th>ID</th>
                            <th>姓名</th>
                            <th>工资</th>
                             <th>操作</th>
                        </tr>
                        </thead>
                        <tbody>
                       <item v-for=" (emp,index)  in empList"   :key="emp.id" :emp="emp" :deleteEmp="deleteEmp"  :index="index"></item>
                       
                        </tbody>
                    </table>
                </div>`;

    window.HomeList = {
        template,
        data() {
            return {
                name: '梦学谷'
            }
        },
        //  声明组件接受父组件传递的属性
        props: {
            empList: Array,
            deleteEmp: Function
        },
        components: {
            Item
        }
    }
})();
